x11/gl: Removing some more legacy GL calls
authorNiels Nesse <nnesse@sonic.net>
Mon, 23 Mar 2015 22:15:08 +0000 (22:15 +0000)
committerEmmanuele Bassi <ebassi@gnome.org>
Mon, 23 Mar 2015 22:16:34 +0000 (22:16 +0000)
They are not required any more.

http://bugzilla.gnome.org/show_bug.cgi?id=746668

gdk/x11/gdkglcontext-x11.c

index 82f50710d7279298ec5f9b4fa1557589c5e8565b..bc36424fafac0e9134d0dabb4f261e7b414ad761 100644 (file)
@@ -462,10 +462,6 @@ gdk_x11_gl_context_texture_from_surface (GdkGLContext *paint_context,
   glGenTextures (1, &texture_id);
   glBindTexture (target, texture_id);
 
-  /* glEnable(GL_TEXTURE_2D) is deprecated */
-  if (target != GL_TEXTURE_2D)
-    glEnable (target);
-
   glTexParameteri (target, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
   glTexParameteri (target, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
   glTexParameteri (target, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
@@ -529,9 +525,6 @@ gdk_x11_gl_context_texture_from_surface (GdkGLContext *paint_context,
   glXReleaseTexImageEXT (glx_pixmap->display, glx_pixmap->drawable,
                         GLX_FRONT_LEFT_EXT);
 
-  if (target != GL_TEXTURE_2D)
-    glDisable (target);
-
   glDeleteTextures (1, &texture_id);
 
   glx_pixmap_destroy(glx_pixmap);